import request from '@/utils/request'



export function pointExchangeList(query) {
  return request({
    url: '/pointExchange/list',
    method: 'get',
    params: query
  })

}


export function deletePointExchange(id) {
  return request({
    url: '/pointExchange/delete',
    method: 'delete',
    params: {pointExchangeId : id }
  })

}

//修改状态
export function updateStatus(id) {
  return request({
    url: '/pointExchange/updateStatus',
    method: 'post',
    params: {id : id}
  })
}

export function addPointExchange(data) {
  return request({
    url: '/pointExchange/add',
    method: 'post',
    data
  })
}

export function updatePointExchange(data) {
  return request({
    url: '/pointExchange/update',
    method: 'put',
    data
  })
}

//查询总数据
export function exchangeStatistics(data) {
  return request({
    url: '/pointExchange/totalStatistic',
    method: 'post',
    data
  })
}

export function exchangeTypeStatistics(data) {
  return request({
    url: '/pointExchange/typeTotalStatistic',
    method: 'post',
    data
  })
}
export function getAllPointList(data) {
  return request({
    url: '/pointExchange/listAllPointExchange',
    method: 'get',
    params: data
  })
}

export function logByPointExchange(data) {
  return request({
    url: '/pointExchange/logByPointExchange',
    method: 'get',
    params: data
  })
}
